package main

import (
	"fmt"
)

func main() {
	// TODO 字符串遍历
	var str = "hello 你好"
	for key, value := range str {
		fmt.Printf("key:%d v:%x value:%c\n", key, value, value)
	}
	// TODO chan遍历
	c := make(chan int)
	go func() {
		c <- 1
		c <- 2
		c <- 3
		close(c)
	}()
	for v := range c {
		fmt.Println(v)
	}
}
